Error diffusion is a method used in halftoning digital image data, and the step of halftoning converts inputted multi-level image data into bi-level output data, also known as a bitmap. In typical error diffusion processes, each input pixel value is compared to a threshold, and if the input is greater than the threshold, then the bi-level output bit is turned ON to print a dot of the particular color being processed. When using 8-bit pixel data, the possible values for the multi-level inputs are in the range of 0-255. In that situation, the dot being printed is typically assigned a value equal to “255.” However, in much image data it is rare that the actual pixel value being submitted to the threshold test is equal to exactly 255, and thus there will be some remaining numeric data value (the “error”) that is spread to other pixel locations that have yet to be processed. This of course is the “diffusion” aspect of error diffusion processing. If all of the image data is “text” or “character” data, which may have values of only zero (0) or “255,” then the error resulting from the threshold test for these numbers would always be zero (0), and there would be no error numeric value to be diffused to neighboring pixels.
However, in continuous tone (“contone”) data, which is typical for any type of computer-generated image or photographic image as the source of image data, the input pixel value will rarely be at “255” since that would be a full saturated color value, and such values would not normally occur in such continuous tone image data. In that situation, the threshold step will produce either a dot to be printed or a white or “blank” space (which is a non-dot), and such values when related to the 8-bit precision of the input data would be worth a value of “255” or “0,” respectively.
If the input pixel value is less than the threshold value, then the output from the threshold test will be turned OFF, and the input numeric value will be spread (or diffused) to its neighboring pixels as the “residual error.” In typical printers available today, the error spreading is done based upon ratios assigned for each direction in which the error will be spread. If the input pixel value is greater than the threshold value, then the difference between the input pixel value and the maximum pixel value (which is typically “255” in an 8-bit system) will become the “residual error” that is spread to the neighboring pixels yet to be processed.
It will be understood that the “next” pixel to be processed will have a component of residual error passed to it from the “previous” pixel that was just processed (and may have additional residual error components from other previously processed pixels as well), and this residual error component is typically added (using an error buffer) to the input pixel value of the input image data at this current pixel location. It is thus possible for a pixel location with an input value of zero (0) to nevertheless have a dot printed in situations where the residual error component added at this particular pixel location happens to be greater than the threshold at this same pixel location. This may occur particularly if a threshold array is used, and this particular array position has a somewhat “low” threshold value, thus making it “easier” for a dot to be printed at this pixel location. Of course, if the input pixel “raw” data was truly at zero (0), then it is unlikely that it would be preferential for a dot to be placed at this pixel location.
In a “smooth” image (also referred to as continuous tone image data), the natural image errors are added to and subtracted from the error buffer throughout the halftoning process for all the pixel locations of the image that is to be rendered into a bitmap. This keeps the error buffer active, and pixels are essentially influenced by their close neighbors only. For character or geometric images, however, the error buffer may become inactive as input image data is processed through blank input pixels, and errors can be carried over limitlessly. Therefore, pixels in one area can influence pixels in another area at quite some distance relative to the overall bitmap for a printed page. One manifestation of this problem occurs when lines may become missing or faint if the image contains very fine parallel lines. Another problem occurs when graphic image data (which could be continuous tone data from photographs, or perhaps from computer-generated graphic data) occurs in one area of a bitmap, and then a large number of blank pixels are found in a consecutive pattern until reaching another set of contone image data, sometimes on the same scanline. In this situation of two different contone images on the same scanline, the residual error from the “last pixel” location of the first image will be carried over to the “first pixel” location of the second image, and this residual error could make the second image's first pixel either more difficult or less difficult to be printed as a dot at that location, strictly due to this “carried over residual error.” Again, pixels in one area may influence pixels in a second area that are some distance from the first area (at least as far as counting rather tiny bitmap pixel locations is concerned).
It would be an improvement to address the problem of such migrating residual error by limiting the extent to which an error can be spread from its origin.